import request from '@/utils/request'

// 查询联系人信息
export function pageList(data) {
    return request({
      url: '/controller/pageList',
      method: 'post',
      data
    })
}

//新增或修改联系人信息
export function addOrUpdateInfo(data) {
    return request({
      url: '/controller/edit',
      method: 'post',
      data
    })
}

//导出联系人
export function exportContacts(query) {
    return request({
      url: '/controller/export',
      method: 'get',
      responseType:'blob',
      params: query
    })
}

// 下载联系人导入模板
export function importTemplate() {
  return request({
    url: '/controller/importTemplate',
    responseType:'blob',
    method: 'get'
  })
}
export function deleteInfo(data) {
  return request({
    url: '/controller/delete',
    method: 'post',
    data
  })
}
